<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript">
        function method01(){
            console.log(window.history.length);
        }

    </script>

</head>
<body>
<button onclick="method01()">获取浏览器中历史浏览记录数量</button>
</body>
</html>